import request from "@/utils/request";

// 查询用户信息列表
export function listAdvisor(query) {
  return request({
    url: "/system/advisorUser/list",
    method: "get",
    params: query
  });
}

// 查询用户信息详细
export function getAdvisor(userId) {
  return request({
    url: "/system/advisorUser/" + userId,
    method: "get"
  });
}

// 新增用户信息
export function addAdvisor(data) {
  return request({
    url: "/system/advisorUser",
    method: "post",
    data: data
  });
}

// 修改用户信息
export function updateAdvisor(data) {
  return request({
    url: "/system/advisorUser",
    method: "put",
    data: data
  });
}

// 删除用户信息
export function delAdvisor(userId) {
  return request({
    url: "/system/advisorUser/" + userId,
    method: "delete"
  });
}

// 导出用户信息
export function exportAdvisor(query) {
  return request({
    url: "/system/advisorUser/export",
    method: "get",
    params: query
  });
}

export function getConfigAdvisor() {
  return request({
    url: "/system/advisorUser/getConfig",
    method: "get"
  });
}

export function updateConfigAdvisor(data) {
  return request({
    url: "/system/advisorUser/matchConfig",
    method: "post",
    data: data
  });
}
